package com.sc.highspeed.service;

import com.sc.highspeed.db.dao.EsCarInfoTempDao;
import com.sc.highspeed.db.model.EsCarInfoModel;
import com.sc.highspeed.db.model.EsCarInfoTempModel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created by Admin on 2017/12/7.
 */
@Service
public class EsCarInfoTempService {

    @Autowired
    private EsCarInfoTempDao esCarInfoTempDao;

    public List<EsCarInfoTempModel> getEsCarInfoByNumber(String number, String color) {
        return esCarInfoTempDao.getEsCarInfoByNumber(number, color);
    }

    public List<EsCarInfoTempModel> getEsCarInfoList(int startRow, int pageSize) {
        return esCarInfoTempDao.getEsCarInfoList(startRow, pageSize);
    }

    public int insertEsCarInfo(EsCarInfoModel esCarInfoModel) {
        return esCarInfoTempDao.insertEsCarInfo(esCarInfoModel);
    }

    public int updateEsCarInfoById(EsCarInfoTempModel esCarInfoTempModel) {
        return esCarInfoTempDao.updateEsCarInfoById(esCarInfoTempModel);
    }

    public int deleteEsCarInfoById(int id) {
        return esCarInfoTempDao.deleteEsCarInfoById(id);
    }

    public EsCarInfoModel getEsCarInfoById(int id) {
        return esCarInfoTempDao.getEsCarInfoById(id);
    }

    public List<EsCarInfoTempModel> getEsCarInfoListByUsername(String creatorUsername) {
        return esCarInfoTempDao.getEsCarInfoListByUsername(creatorUsername);
    }

    public List<EsCarInfoTempModel> getHazyEsCarInfo(String number, String color) {
        return esCarInfoTempDao.getHazyEsCarInfo(number, color);
    }

    public EsCarInfoTempModel getEsCarInfoByEsId(int esId) {
        return esCarInfoTempDao.getEsCarInfoByEsId(esId);
    }

    public int getEsCarInfoNumber() {
        return esCarInfoTempDao.getEsCarInfoNumber();
    }
}
